﻿var uagent = navigator.userAgent.toLowerCase();
var is_safari = ((uagent.indexOf('safari') != -1) || (navigator.vendor == "Apple Computer, Inc."));
var is_opera = (uagent.indexOf('opera') != -1);
var is_webtv = (uagent.indexOf('webtv') != -1);
var is_ie = ((uagent.indexOf('msie') != -1) && (!is_opera) && (!is_safari) && (!is_webtv));
var is_ie4 = ((is_ie) && (uagent.indexOf("msie 4.") != -1));
var is_moz = ((navigator.product == 'Gecko') && (!is_opera) && (!is_webtv) && (!is_safari));
var is_ns = ((uagent.indexOf('compatible') == -1) && (uagent.indexOf('mozilla') != -1) && (!is_opera) && (!is_webtv) && (!is_safari));
var is_ns4 = ((is_ns) && (parseInt(navigator.appVersion) == 4));
var is_opera = (uagent.indexOf('opera') != -1);
var is_kon = (uagent.indexOf('konqueror') != -1);
var is_webtv = (uagent.indexOf('webtv') != -1);

var is_win = ((uagent.indexOf("win") != -1) || (uagent.indexOf("16bit") != -1));
var is_mac = ((uagent.indexOf("mac") != -1) || (navigator.vendor == "Apple Computer, Inc."));
var ua_vers = parseInt(navigator.appVersion);

// JavaScript Document
var NameC = "华招产品采购系统";
var NameE = "";
var address = "";
var post = "";
var tel = "";
var fax = "";
var email = "";
var jdbtel = "";

var fileName = window.location.href.split("//")[1].split("/");
var pathName = fileName[fileName.length - 2];
fileName = pathName + "/" + fileName[fileName.length - 1].split(".")[0] + ".htm";

//倒计时有关参数
var timespan;
var timeShowText;
var timeAlertText;
var doc_height;

//层宽度相关参数
var nav_width = 190;
var body_width = 950;
var help_width = 180;

var current_nav_width = 190;
var current_help_width = 0;

var tdMaxWidth = 200; //单元格最大宽度
var tdMaxTextNum = 20; //单元格最大字符数

var winWidth = 0; //窗口可视宽度
var winHeight = 0; //窗口可视高度
function findDimensions()
//函数：获取尺寸  
{   //获取窗口宽度   
    if (window.innerWidth) winWidth = window.innerWidth;
    else if ((document.body) && (document.body.clientWidth)) winWidth = document.body.clientWidth;
    //获取窗口高度   
    if (window.innerHeight) winHeight = window.innerHeight;
    else if ((document.body) && (document.body.clientHeight))
        winHeight = document.body.clientHeight;
    //通过深入Document内部对body进行检测，获取窗口大小 
    if (document.documentElement && document.documentElement.clientHeight && document.documentElement.clientWidth)
    { winHeight = document.documentElement.clientHeight; winWidth = document.documentElement.clientWidth; }
}

function utf8_encode(string) {
    return encodeURI(string).replace(/\+/g, "%2B").replace(/(%20)+/, "+");
}

//左右列高度变化
function bodyresize() {
    try {
        if (document.body.clientHeight > winHeight) {

            var h1 = leftHeight;
            var h2 = document.getElementById("body-wrap").scrollHeight;
            if (h1 > h2) {
                if (is_ie)
                    document.getElementById("body-wrap").style.height = h1 - 20;
                else
                    document.getElementById("body-wrap").style.height = (h1 - 20) + "px";
            }
            else {
                if (is_ie)
                    document.getElementById("nav").style.height = h2;
                else {
                    document.getElementById("nav").style.height = (h2) + "px";
                }
            }
        }
        else {
            if (is_ie) {
                document.getElementById("nav").style.height = winHeight - 157;
                document.getElementById("body-wrap").style.height = winHeight - 177;
            }
            else {
                document.getElementById("nav").style.height = (winHeight - 157) + "px";
                document.getElementById("body-wrap").style.height = (winHeight - 177) + "px";
            }
        }
        if (document.getElementById("timeAlert")) {
            if (is_ie) {
                document.getElementById("body-wrap").style.height = document.getElementById("body-wrap").offsetHeight - document.getElementById("timeAlert").offsetHeight - 30;
            }
            else {
                document.getElementById("body-wrap").style.height = (document.getElementById("body-wrap").offsetHeight - document.getElementById("timeAlert").offsetHeight - 30) + "px";
            }
        }
    }
    catch (e) { alert(e.message); }
    if (document.getElementById("ctl00_ContentPlaceHolder1_C1WebGrid1") != null && document.getElementById("ctl00_ContentPlaceHolder1_C1WebGrid1").parentNode.parentNode.id == "yljgList") {
        resizeTable("yljgList", "ctl00_ContentPlaceHolder1_C1WebGrid1");
        //				document.getElementById("ctl00_ContentPlaceHolder1_C1WebGrid1").style.tableLayout="fixed";
    }
}

try {
    YAHOO.util.Event.onDOMReady(

        function() {

            var IE_QUIRKS = (YAHOO.env.ua.ie && document.compatMode == "BackCompat");

            var IE_SYNC = (YAHOO.env.ua.ie == 6 || (YAHOO.env.ua.ie == 7 && IE_QUIRKS));

            var PANEL_BODY_PADDING = (10 * 2) //

            var panel = new YAHOO.widget.Panel('resizablepanel', {
                draggable: true,
                width: '500px',
                visible: false,
                fixedcenter: true,
                zIndex: 1030,
                context: ["showbtn", "tl", "bl"]
            });
            panel.render();

            var resize = new YAHOO.util.Resize('resizablepanel', {
                handles: ['br'],
                autoRatio: false,
                minWidth: 300,
                minHeight: 100,
                status: true
            });

            resize.on('resize', function(args) {

                var panelHeight = args.height;

                var headerHeight = this.header.offsetHeight; // Content + Padding + Border
                var footerHeight = this.footer.offsetHeight; // Content + Padding + Border

                var bodyHeight = (panelHeight - headerHeight - footerHeight);
                var bodyContentHeight = (IE_QUIRKS) ? bodyHeight : bodyHeight - PANEL_BODY_PADDING;

                YAHOO.util.Dom.setStyle(this.body, 'height', bodyContentHeight + 'px');

                if (IE_SYNC) {

                    this.sizeUnderlay();

                    this.syncIframe();
                }
            }, panel, true);

            YAHOO.util.Event.on("helpcontrol", "click", panel.show, panel, true);
        }
    );
}
catch (ex) { }

function resizeTable(divName, tableName) {
    var tds = document.getElementById(tableName).getElementsByTagName("td");
    if (tds.length > 0) {
        var tableWidth = 100 * document.getElementById(tableName).childNodes[0].childNodes.length;
        tableWidth = (tableWidth > document.getElementById("body-wrap").clientWidth - 30) ? tableWidth : document.getElementById("body-wrap").clientWidth - 30;

        document.getElementById(tableName).style.width = tableWidth;
        for (i = 0; i < tds.length; i++) {
            if (tds[i].clientWidth > tdMaxWidth && tds[i].title == "") {
                tds[i].style.width = tdMaxWidth;
                //alert(tds[i].innerText);
                tds[i].title = tds[i].innerText;
                tds[i].className = "hidden";
                tds[i].onclick = function() { window.open('../Common/TopTip.aspx?param=' + utf8_encode(this.title), 'newwindow', 'height=300, width=400, top=' + (winHeight - 300) / 2 + ', left=' + (winWidth - 400) / 2 + ', toolbar=no, menubar=no, scrollbars=yes,resizable=yes,location=no, status=no'); }
                tds[i].style.cursor = "hand";
                if (tds[i].innerText.length > tdMaxTextNum)
                    tds[i].innerText = tds[i].innerText.substring(0, tdMaxTextNum) + '...';
            }
        }
    }
}

function ShowFooter() {
    //document.writeln("<div style=\"clear:both;position:relative\" align=\"center\" id=\"bottom-wrap\"><br/>Copyright &copy; " + new Date().getFullYear() + " " + NameC + " 版权所有<br \/>");
    //document.writeln("		华招网信息技术有限公司技术支持");
    //document.writeln("<\/div>");

    document.writeln("<div style=\"clear:both; position:relative;text-align:center;padding-top:10px;\" id=\"bottom-wrap\">Copyright &copy; " + new Date().getFullYear() + " " + NameC + " 版权所有<br/>");
    document.writeln("		华招网信息技术有限公司技术支持");
    document.writeln("<\/div>");

    findDimensions();
}

function PageHeight() {
    if (document.getElementById("nav") != null && document.getElementById("body-wrap") != null) {
        //alert(screen.availHeight+"---"+window.screenTop);
        var screenHeight = screen.availHeight - window.screenTop - 208;
        var h1 = parseInt(document.getElementById("nav").offsetHeight);
        var h2 = parseInt(document.getElementById("body-wrap").offsetHeight);
        alert(document.getElementById("body-wrap").style.height);
        if (document.getElementById("body-wrap").style.height != "") {
            h2 = parseInt(document.getElementById("body-wrap").style.height);
        }
        alert(h1 + "," + h2);
        doc_height = (h1 >= h2) ? h1 : h2;
        doc_height = (screenHeight >= doc_height) ? screenHeight : doc_height;
        //
        document.getElementById("nav").style.height = doc_height;
        document.getElementById("body-wrap").style.height = doc_height;
        if (document.getElementById("timeAlert")) {
            document.getElementById("body-wrap").style.height = doc_height - document.getElementById("timeAlert").offsetHeight - 10;
        }
        //	    document.getElementById("nav_control").style.height=h1;
    }
}

function AppendHelpSpan() {
    if (document.getElementById("wrap") != null) {
        document.getElementById("helpiframe").src = "../help/" + fileName;
    }
    /*
    if(document.getElementById("wrap")!=null) {
    var help = document.createElement("div");
    help.id = "help"; 
    help.style.wordBreak="normal";
    help.style.wordWrap="break-word";
    help.style.display="none";
    //help.innerHTML = "<img id=\"imgforhelp\" src=\"../images/help.gif\" onload=\"helpfind('x');\" /><div id=\"resizablepanel\"><div class=\"hd\">帮</div><div class=\"bd\"><iframe id=\"helpiframe\" height=\"100%\" width=\"100%\"></iframe></div><div class=\"ft\">houshengtao</div>";
    help.innerHTML = "<div id=\"help_div\">系统帮助</div><hr/>当前帮助页面地址为：/help/" + fileName + ".htm";
    document.getElementById("wrap").appendChild(help);
    }
    */
}

function ShowNav() {
    var n = document.getElementById("nav");
    var b = document.getElementById("body-wrap");
    var t = document.getElementById("body-wrap-top");
    if (n.style.display == "block" || n.style.display == "") {
        n.style.display = "none";
        current_nav_width = 0;
        document.getElementById("nav_control").className = "nav_control_show";
    }
    else {
        n.style.display = "block";
        current_nav_width = nav_width;
        document.getElementById("nav_control").className = "nav_control_hidden";
    }
    n.style.width = current_nav_width;
    b.style.width = body_width - current_nav_width - current_help_width;
    t.style.width = body_width - current_nav_width;
}

function ShowHeader() {
    header_Title = "";
    if (GetCookie("ProjectName") == null)
        header_Title = NameC;
    else
        header_Title = decodeURIComponent(GetCookie("ProjectName"));
    document.writeln("<div id=\"logo\"><script type=\"text/javascript\">document.write(header_Title);</script></div>");
    //	document.writeln("<div id=\"page-top-right\"></div>");
}
//给相应的form里的input赋值
//document.form_name.input_name.value = getck("username");



//参数说明：
//loc -- 当前位置
//member -- 当前用户
//ShowText -- 倒计时什么
//AlertText -- 倒计时到期弹出文字
function ShowTopNav(loc, member, ShowText, AlertText) {
    timeShowText = ShowText;
    timeAlertText = AlertText;
    //	var s="<table><td style=\"width:30%;\" id=\"currentuser\">当前用户："+member+"</td><td id=\"position\" style=\"width:30%;\">当前位置："+loc+"</td>";
    //	if(timeShowText!="")
    //	{
    //		s+="<td style=\"width:40%;\" id=\"Countdown\">"+ShowText+"：<span id=\"Countdowns\"></span></td>";
    //	}
    //	s+="<td style=\"text-align;right;\"><div id=\"helpcontrol\" tip=\"帮助小贴士\" onclick=\"ShowHelp();\"></div></td></tr></table>";


    var memberDiv = document.createElement("div");
    memberDiv.id = "header-right";
    memberDiv.innerHTML = "<strong style=\"margin-right:10px;\" id=\"current_user\">当前用户：" + member + "</strong> | <a style=\"margin-right:5px;width:16px;\" id=\"tb_speed_icon\" class=\"icon_speed_1\" alt=\"\" ></a><a id=\"helpcontrol\" style=\"margin-right:10px;\" href=\"#\" onclick=\"ShowHelp();\">系统帮助</a><a id=\"re-login-system\" href=\"#\" style=\"margin-right:10px;\" onclick=\"javascript:ReLogin();\">重新登录</a><a href=\"#\" id=\"close-system\" style=\"margin-right:10px;\" onclick=\"javascript:self.close();\">关闭系统</a>";
    document.getElementById("page-top").insertBefore(memberDiv, document.getElementById("page-top").childNodes[1]);

    SpeedTest();
}

//ShowText -- 倒计时什么
//AlertText -- 倒计时到期弹出文字
function showalert(ShowText, AlertText) {
    if (ShowText != "" && AlertText != "") {
        var s = "<div style=\"margin:5px 0px 5px 0px;width:100%;\" id=\"timeAlert\"><table cellpadding=\"0\" cellspacing=\"0\" ><tr><td id=\"alert_left\" class=\"alert_left\"></td><td class=\"alert_clock\"></td><td id=\"alert_text\" class=\"alert_text\">" + ShowText + "：<span id=\"Countdowns\" style=\"font-weight:bold\"></span></td><td class=\"alert_right\"></td></tr></table></div>";
        document.getElementById("body-wrap-top").innerHTML = s; showAlertTime();
        setInterval("showAlertTime()", 1000);
    }
}

/*测试页面打开速度开始*/
function SpeedTest() {
    if (typeof (_s_) != "undefined") {
        showSpeedInfoBar(getSpeedInfo((new Date() - _s_)));
    }
    else {
        document.getElementById("tb_speed_icon").style.display = "none";
    }
}

function showSpeedInfoBar(infoObj) {
    document.getElementById("tb_speed_icon").className = "icon_speed_" + infoObj.lv;
    document.getElementById("tb_speed_icon").alt = infoObj.tip;
    document.getElementById("tb_speed_icon").title = infoObj.tip;
    document.getElementById("tb_speed_icon").innerText = infoObj.summary;
}

function getSpeedInfo(tn) {
    tn = (typeof (tn) == 'number') ? (tn / 1000) : 3;
    var res = {};
    if (tn < 15) {
        res.summary = (tn < 3) ? "闪电般速度" : ((tn < 5) ? "速度相当快" : "速度不错喔"); res.tip = "您打开本页面所用时间仅为" + tn + "秒，速度相当快喔！"; res.lv = 1;
    }
    else if (tn < 30) {
        res.summary = "速度待改进！"; res.tip = "您打开本页面所用时间为" + tn + "秒，速度有待改进喔！"; res.lv = 2;
    }
    else {
        res.summary = "网络有延时"; res.tip = "您打开本页面所用时间大于30秒，请您检查一下您的网络状况。"; res.lv = 3;
    }
    return res;
}
/*测试页面打开速度结束*/


function getValue(offset) {
    var endstr = document.cookie.indexOf(";", offset);
    if (endstr == -1)
        endstr = document.cookie.length;
    return decodeURIComponent(document.cookie.substring(offset, endstr));
}
function GetCookie(name) {
    var arg = name + "=";
    var arg_len = arg.length;
    var cookie_length = document.cookie.length;
    var i = 0;
    while (i < cookie_length) {
        var j = i + arg_len;
        if (document.cookie.substring(i, j) == arg) {
            return getValue(j);
        }
        i = document.cookie.indexOf(" ", i) + 1;
        if (i == 0) break;
    }
    return null;
}
function SetCookie(name, value, expires) {
    document.cookie = name + "=" + encodeURIComponent(value) + ";expires=" + expires.toGMTString() + ";path=/;";
}

function ShowHelp() {
    if (document.getElementById("resizablepanel") != null) {
        if (document.getElementById("resizablepanel").style.display == "none")
            document.getElementById("resizablepanel").style.display = "block";
        else
            document.getElementById("resizablepanel").style.display = "none";
    }
}

function ShowSearch() {
    var s = document.getElementById("trade-search-bd");
    if (s.style.display == "block" || s.style.display == "") {
        s.style.display = "none";
        document.getElementById("toggle").className = "panel-toggle-over";
    }
    else {
        s.style.display = "block";
        document.getElementById("toggle").className = "panel-toggle";
    }
}

function ShowBottomNav() {
    //var s="<ul><li><span id=\"re-login-system\" onclick=\"javascript:ReLogin();\">重新登录</span></li><li><span id=\"close-system\" onclick=\"javascript:alert('关闭系统');\">关闭系统</span></li></ul>";
    //document.getElementById("nav_bottom").innerHTML=s;
}

function ReLogin() {
    if (confirm('确定要重新登录？')) {
        document.forms[0].action = "../Common/Login.aspx";
        document.forms[0].submit();
    }
}

function showAlertTime() {
    if (parseInt(timespan) > 0) {
        day = Math.floor(timespan / 86400);  //倒计时天数;
        deltime = timespan % 86400;
        hour = Math.floor(deltime / 3600);   //倒计时小时数
        deltime = timespan % 3600;
        min = Math.floor(deltime / 60);     //倒计时分钟数
        sec = Math.floor(deltime % 60)                 //倒计时秒数

        timespan--;     //倒计时的时间(秒数)

        document.getElementById("Countdowns").innerHTML = "<b style='color:red;'>" +
                              day + "</b>天<b style='color:red;'>" +
                              hour + "</b>小时<b style='color:red;'>" +
                              min + "</b>分<b style='color:red;'>" +
                              sec + "</b>秒";
        if (is_ie)
            document.getElementById("alert_left").style.width = document.getElementById("timeAlert").clientWidth - document.getElementById("alert_text").offsetWidth - 57;
        else
            document.getElementById("alert_left").style.width = (document.getElementById("timeAlert").clientWidth - document.getElementById("alert_text").offsetWidth - 57) + "px";
    } else {
        //       alert(timeAlertText);
        //       self.close();
    }
}

function ShowTime() {
    try {
        var x, h, m, s, n;
        var x = new Date();
        yy = x.getYear();
        mm = x.getMonth() + 1;
        dd = x.getDate();
        xq = x.getDay();
        switch (xq) {
            case 0:
                xq = "日";
                break;
            case 1:
                xq = "一";
                break;
            case 2:
                xq = "二";
                break;
            case 3:
                xq = "三";
                break;
            case 4:
                xq = "四";
                break;
            case 5:
                xq = "五";
                break;
            case 6:
                xq = "六";
                break;

        }
        n = yy + "年" + mm + "月" + dd + "日" + "    星期" + xq;
        document.getElementById("Time").innerHTML = n;
        setTimeout("ShowTime()", 1000);
    }
    catch (e) { alert(e); }
}
//管理员左侧菜单
function ShowLeftItems(Show, CurrentShow) {
    ShowLeftItemsTop();
    document.writeln("<dl id=\"libCatalog\">");

    //add by hou at 2008-09-27
    //基础库信息管理
    if (Show == "基础库信息管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='医疗机构管理.htm'\">基础库信息管理</dt>");

        if (CurrentShow == "基础库审核设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"基础库审核设置.htm\">基础库审核设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"基础库审核设置.htm\">基础库审核设置</a></dd>");

        if (CurrentShow == "医疗机构管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"医疗机构管理.htm\">医疗机构管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"医疗机构管理.htm\">医疗机构管理</a></dd>");
        if (CurrentShow == "医疗机构审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"医疗机构审核管理.htm\">医疗机构审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"医疗机构审核管理.htm\">医疗机构审核管理</a></dd>");

        if (CurrentShow == "专家类别管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"专家类别管理.htm\">专家类别管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"专家类别管理.htm\">专家类别管理</a></dd>");

        if (CurrentShow == "专家管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"专家管理.htm\">专家管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"专家管理.htm\">专家管理</a></dd>");

        if (CurrentShow == "专家审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"专家审核管理.htm\">专家审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"专家审核管理.htm\">专家审核管理</a></dd>");

        if (CurrentShow == "设置筛选权重")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"设置筛选权重.htm\">设置筛选权重</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"设置筛选权重.htm\">设置筛选权重</a></dd>");

        if (CurrentShow == "打专家分")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"打专家分.htm\">打专家分</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"打专家分.htm\">打专家分</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='医疗机构管理.htm'\">基础库信息管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"基础库审核设置.htm\">基础库审核设置</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"医疗机构管理.htm\">医疗机构管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"医疗机构审核管理.htm\">医疗机构审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"专家类别管理.htm\">专家类别管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"专家管理.htm\">专家管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"专家审核管理.htm\">专家审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"设置筛选权重.htm\">设置筛选权重</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"打专家分.htm\">打专家分</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");
    //end 2008-09-27

    if (Show == "字段管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='字段管理.htm'\">字段管理</dt>");
        if (CurrentShow == "新建字段")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"新建字段.htm\">新建字段</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"新建字段.htm\">新建字段</a></dd>");

        if (CurrentShow == "字段管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"字段管理.htm\">字段管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"字段管理.htm\">字段管理</a></dd>");

        if (CurrentShow == "各模块字段管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"各模块字段管理.htm\">各模块字段管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"各模块字段管理.htm\">各模块字段管理</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='字段管理.htm'\">字段管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"新建字段.htm\">新建字段</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"字段管理.htm\">字段管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"各模块字段管理.htm\">各模块字段管理</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    //start 2008-09-19
    if (Show == "基本产品信息管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='基本产品信息.htm'\">基本产品信息管理</dt>");
        if (CurrentShow == "基本产品信息")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"基本产品信息.htm\">基本产品信息</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"基本产品信息.htm\">基本产品信息</a></dd>");

        if (CurrentShow == "基本产品类别管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"基本产品类别管理.htm\">基本产品类别管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"基本产品类别管理.htm\">基本产品类别管理</a></dd>");

        if (CurrentShow == "基本产品对应选择")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"基本产品对应选择.htm\">基本产品对应选择</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"基本产品对应选择.htm\">基本产品对应选择</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='基本产品信息.htm'\">基本产品信息管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"基本产品信息.htm\">基本产品信息</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"基本产品类别管理.htm\">基本产品类别管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"基本产品对应选择.htm\">基本产品对应选择</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");
    //end 2008-09-19

    if (Show == "用户管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='用户列表.htm'\">用户管理</dt>");
        if (CurrentShow == "新建用户注册子项目")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"新建用户注册子项目.htm\">新建用户注册子项目</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"新建用户注册子项目.htm\">新建用户注册子项目</a></dd>");

        if (CurrentShow == "用户注册子项目管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户注册子项目列表.htm\">用户注册子项目管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户注册子项目列表.htm\">用户注册子项目管理</a></dd>");

        if (CurrentShow == "用户列表")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户列表.htm\">用户列表</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户列表.htm\">用户列表</a></dd>");

        if (CurrentShow == "用户审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户审核管理.htm\">用户审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户审核管理.htm\">用户审核管理</a></dd>");

        if (CurrentShow == "用户权限设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户权限设置.htm\">用户权限设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户权限设置.htm\">用户权限设置</a></dd>");

        if (CurrentShow == "用户类型管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户类型管理.htm\">用户类型管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户类型管理.htm\">用户类型管理</a></dd>");

        if (CurrentShow == "用户注册子项目默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户注册子项目默认设置.htm\">用户注册子项目默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户注册子项目默认设置.htm\">用户注册子项目默认设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='用户列表.htm'\">用户管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"新建用户注册子项目.htm\">新建用户注册子项目</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户注册子项目列表.htm\">用户注册子项目管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户列表.htm\">用户列表</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户审核管理.htm\">用户审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户权限设置.htm\">用户权限设置</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户类型管理.htm\">用户类型管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户注册子项目默认设置.htm\">用户注册子项目默认设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "企业资质填报管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='企业资质填报子项目管理.htm'\">企业资质填报管理</dt>");
        if (CurrentShow == "新建企业资质填报子项目")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"新建企业资质填报子项目.htm\">新建企业资质填报子项目</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"新建企业资质填报子项目.htm\">新建企业资质填报子项目</a></dd>");

        if (CurrentShow == "企业资质填报子项目管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业资质填报子项目管理.htm\">企业资质填报子项目管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"企业资质填报子项目管理.htm\">企业资质填报子项目管理</a></dd>");

        if (CurrentShow == "企业资质填报审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业资质填报审核管理.htm\">企业资质填报审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"企业资质填报审核管理.htm\">企业资质填报审核管理</a></dd>");

        if (CurrentShow == "企业填报子项目默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业填报子项目默认设置.htm\">企业填报子项目默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"企业填报子项目默认设置.htm\">企业填报子项目默认设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='企业资质填报子项目管理.htm'\">企业资质填报管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"新建企业资质填报子项目.htm\">新建企业资质填报子项目</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"企业资质填报子项目管理.htm\">企业资质填报子项目管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"企业资质填报审核管理.htm\">企业资质填报审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"企业填报子项目默认设置.htm\">企业填报子项目默认设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "商品资质填报管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='商品资质填报子项目管理.htm'\">商品资质填报管理</dt>");
        if (CurrentShow == "新建商品资质填报子项目")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"新建商品资质填报子项目.htm\">新建商品资质填报子项目</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"新建商品资质填报子项目.htm\">新建商品资质填报子项目</a></dd>");

        if (CurrentShow == "商品资质填报子项目管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品资质填报子项目管理.htm\">商品资质填报子项目管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品资质填报子项目管理.htm\">商品资质填报子项目管理</a></dd>");

        if (CurrentShow == "商品资质填报审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品资质填报审核管理.htm\">商品资质填报审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品资质填报审核管理.htm\">商品资质填报审核管理</a></dd>");

        if (CurrentShow == "商品填报子项目默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品填报子项目默认设置.htm\">商品填报子项目默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品填报子项目默认设置.htm\">商品填报子项目默认设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='商品资质填报子项目管理.htm'\">商品资质填报管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"新建商品资质填报子项目.htm\">新建商品资质填报子项目</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品资质填报子项目管理.htm\">商品资质填报子项目管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品资质填报审核管理.htm\">商品资质填报审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品填报子项目默认设置.htm\">商品填报子项目默认设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "商品报价管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='商品报价子项目管理.htm'\">商品报价管理</dt>");
        if (CurrentShow == "新建商品报价子项目")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"新建商品报价子项目.htm\">新建商品报价子项目</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"新建商品报价子项目.htm\">新建商品报价子项目</a></dd>");

        if (CurrentShow == "商品报价子项目管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品报价子项目管理.htm\">商品报价子项目管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品报价子项目管理.htm\">商品报价子项目管理</a></dd>");

        if (CurrentShow == "商品报价统计查看")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"选择商品报价子项目.htm\">商品报价统计查看</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"选择商品报价子项目.htm\">商品报价统计查看</a></dd>");

        if (CurrentShow == "商品报价解密")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品报价解密.htm\">商品报价解密</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品报价解密.htm\">商品报价解密</a></dd>");

        if (CurrentShow == "商品报价轮次默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品报价轮次默认设置.htm\">商品报价轮次默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品报价轮次默认设置.htm\">商品报价轮次默认设置</a></dd>");

        if (CurrentShow == "商品报价子项目默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品报价子项目默认设置.htm\">商品报价子项目默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品报价子项目默认设置.htm\">商品报价子项目默认设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='商品报价子项目管理.htm'\">商品报价管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"新建商品报价子项目.htm\">新建商品报价子项目</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品报价子项目管理.htm\">商品报价子项目管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"选择商品报价子项目.htm\">商品报价统计查看</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品报价解密.htm\">商品报价解密</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品报价轮次默认设置.htm\">商品报价轮次默认设置</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品报价子项目默认设置.htm\">商品报价子项目默认设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    //专家抽取系统
    if (Show == "专家抽取系统") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='专家抽取子项目管理.htm'\">专家抽取系统</dt>");

        if (CurrentShow == "新建专家抽取子项目")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"新建专家抽取子项目.htm\">新建专家抽取子项目</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"新建专家抽取子项目.htm\">新建专家抽取子项目</a></dd>");
        if (CurrentShow == "专家抽取子项目管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"专家抽取子项目管理.htm\">专家抽取子项目管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"专家抽取子项目管理.htm\">专家抽取子项目管理</a></dd>");

        if (CurrentShow == "专家入库")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"专家入库.htm\">专家入库</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"专家入库.htm\">专家入库</a></dd>");

        if (CurrentShow == "专家抽取")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"专家抽取.htm\">专家抽取</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"专家抽取.htm\">专家抽取</a></dd>");

        if (CurrentShow == "专家抽取子项目默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"专家抽取子项目默认设置.htm\">专家抽取子项目默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"专家抽取子项目默认设置.htm\">专家抽取子项目默认设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='专家抽取子项目管理.htm'\">专家抽取系统</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"新建专家抽取子项目.htm\">新建专家抽取子项目</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"专家抽取子项目管理.htm\">专家抽取子项目管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"专家入库.htm\">专家入库</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"专家抽取.htm\">专家抽取</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"专家抽取子项目默认设置.htm\">专家抽取子项目默认设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "公示管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='公示审核管理.htm'\">公示管理</dt>");
        if (CurrentShow == "公示审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"公示审核管理.htm\">公示审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"公示审核管理.htm\">公示审核管理</a></dd>");

        if (CurrentShow == "公示系统设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"公示系统设置.htm\">公示系统设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"公示系统设置.htm\">公示系统设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='公示审核管理.htm'\">公示管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"公示审核管理.htm\">公示审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"公示系统设置.htm\">公示系统设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "站内短信管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='我的短信.htm'\">站内短信管理</dt>");
        if (CurrentShow == "新建站内短信")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        if (CurrentShow == "收件箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        if (CurrentShow == "草稿箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        if (CurrentShow == "发件箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        if (CurrentShow == "垃圾箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='我的短信.htm'\">站内短信管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "短信发送管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='短信发送子项目管理.htm'\">短信发送管理</dt>");
        if (CurrentShow == "密码修改")
            document.writeln("<dd style=\"left_nav_item left_nav_item_current\"><a href=\"短信发送子项目管理.htm\">短信发送管理</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"短信发送子项目管理.htm\">短信发送管理</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='短信发送子项目管理.htm'\">短信发送管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"短信发送子项目管理.htm\">短信发送管理</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "个人信息管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='密码修改.htm'\">个人信息管理</dt>");
        if (CurrentShow == "密码修改")
            document.writeln("<dd style=\"left_nav_item left_nav_item_current\"><a href=\"密码修改.htm\">密码修改</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"密码修改.htm\">密码修改</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='密码修改.htm'\">个人信息管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"密码修改.htm\">密码修改</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "系统设置") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='系统设置.htm'\">系统设置</dt>");
        if (CurrentShow == "系统设置")
            document.writeln("<dd style=\"left_nav_item left_nav_item_current\"><a href=\"系统设置.htm\">系统设置</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"系统设置.htm\">系统设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='系统设置.htm'\">系统设置</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"系统设置.htm\">系统设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    document.writeln("</dl>");
    ShowLeftItemsBottom();
}

//操作员左侧菜单
function ShowLeftItemsOperator(Show, CurrentShow) {
    ShowLeftItemsTop();
    document.writeln("<dl id=\"libCatalog\">");

    if (Show == "用户管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='用户注册子项目列表.htm'\">用户管理</dt>");
        if (CurrentShow == "用户注册子项目列表")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户注册子项目列表.htm\">用户注册子项目列表</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户注册子项目列表.htm\">用户注册子项目列表</a></dd>");

        if (CurrentShow == "用户列表")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户列表.htm\">用户列表</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户列表.htm\">用户列表</a></dd>");

        if (CurrentShow == "用户审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户审核管理.htm\">用户审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户审核管理.htm\">用户审核管理</a></dd>");

        if (CurrentShow == "用户注册子项目默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"用户注册子项目默认设置.htm\">用户注册子项目默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"用户注册子项目默认设置.htm\">用户注册子项目默认设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='用户列表.htm'\">用户管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户注册子项目列表.htm\">用户注册子项目列表</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户列表.htm\">用户列表</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户审核管理.htm\">用户审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"用户注册子项目默认设置.htm\">用户注册子项目默认设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "企业资质填报管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='企业资质填报子项目管理.htm'\">企业资质填报管理</dt>");
        if (CurrentShow == "企业资质填报子项目管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业资质填报子项目管理.htm\">企业资质填报子项目管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"企业资质填报子项目管理.htm\">企业资质填报子项目管理</a></dd>");

        if (CurrentShow == "企业资质填报审核管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业资质填报审核管理.htm\">企业资质填报审核管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"企业资质填报审核管理.htm\">企业资质填报审核管理</a></dd>");

        if (CurrentShow == "企业填报子项目默认设置")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业填报子项目默认设置.htm\">企业填报子项目默认设置</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"企业填报子项目默认设置.htm\">企业填报子项目默认设置</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='企业资质填报子项目管理.htm'\">企业资质填报管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"企业资质填报子项目管理.htm\">企业资质填报子项目管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"企业资质填报审核管理.htm\">企业资质填报审核管理</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"企业填报子项目默认设置.htm\">企业填报子项目默认设置</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "公示管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='公示列表.htm'\">公示管理</dt>");
        if (CurrentShow == "新建公示")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"新建公示.htm\">新建公示</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"新建公示.htm\">新建公示</a></dd>");

        if (CurrentShow == "公示列表")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"公示列表.htm\">公示列表</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"公示列表.htm\">公示列表</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='公示列表.htm'\">公示管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"新建公示.htm\">新建公示</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"公示列表.htm\">公示列表</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "站内短信管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='我的短信.htm'\">站内短信管理</dt>");
        if (CurrentShow == "新建站内短信")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        if (CurrentShow == "收件箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        if (CurrentShow == "草稿箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        if (CurrentShow == "发件箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        if (CurrentShow == "垃圾箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='我的短信.htm'\">站内短信管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");


    if (Show == "个人信息管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='密码修改.htm'\">个人信息管理</dt>");
        if (CurrentShow == "密码修改")
            document.writeln("<dd style=\"left_nav_item left_nav_item_current\"><a href=\"密码修改.htm\">密码修改</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"密码修改.htm\">密码修改</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='密码修改.htm'\">个人信息管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"密码修改.htm\">密码修改</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    document.writeln("</dl>");
    ShowLeftItemsBottom();
}

//企业用户左侧菜单
function ShowLeftItemsEnterprise(Show, CurrentShow) {
    ShowLeftItemsTop();
    document.writeln("<dl id=\"libCatalog\">");

    if (Show == "企业资质填报管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='企业资质信息修正.htm'\">企业资质填报管理</dt>");
        //	    if(CurrentShow=="企业资质填报")
        //	        document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业资质填报.htm\">企业资质填报</a></dd>");
        //	    else
        //	        document.writeln("<dd class=\"left_nav_item\"><a href=\"企业资质填报.htm\">企业资质填报</a></dd>");
        if (CurrentShow == "企业资质信息修正")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"企业资质信息修正.htm\">企业资质信息修正</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"企业资质信息修正.htm\">企业资质信息修正</a></dd>");
        if (CurrentShow == "生产企业对应关系管理")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"生产企业对应关系管理.htm\">生产企业对应关系管理</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"生产企业对应关系管理.htm\">生产企业对应关系管理</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='企业资质信息修正.htm'\">企业资质填报管理</dt>");
        //document.writeln("<dd style=\"display:none;\"><a href=\"企业资质填报.htm\">企业资质填报</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"企业资质信息修正.htm\">企业资质信息修正</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"生产企业对应关系管理.htm\">生产企业对应关系管理</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "商品资质填报管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='选择填报项目.htm'\">商品资质填报管理</dt>");

        if (CurrentShow == "商品资质填报")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"选择填报项目.htm\">商品资质填报</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"选择填报项目.htm\">商品资质填报</a></dd>");

        if (CurrentShow == "已填报商品列表")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"已填报商品列表.htm\">已填报商品列表</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"已填报商品列表.htm\">已填报商品列表</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='选择填报项目.htm'\">商品资质填报管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"选择填报项目.htm\">商品资质填报</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"已填报商品列表.htm\">已填报商品列表</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "商品报价管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='商品报价.htm'\">商品报价管理</dt>");
        if (CurrentShow == "商品报价")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"商品报价.htm\">商品报价</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"商品报价.htm\">商品报价</a></dd>");
        if (CurrentShow == "已报价商品列表")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"已报价商品列表.htm\">已报价商品列表</a></dd>");
        else
            document.writeln("<dd class=\"left_nav_item\"><a href=\"已报价商品列表.htm\">已报价商品列表</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='商品报价.htm'\">商品报价管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"商品报价.htm\">商品报价</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"已报价商品列表.htm\">已报价商品列表</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "站内短信管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='我的短信.htm'\">站内短信管理</dt>");
        if (CurrentShow == "新建站内短信")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        if (CurrentShow == "收件箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        if (CurrentShow == "草稿箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        if (CurrentShow == "发件箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        if (CurrentShow == "垃圾箱")
            document.writeln("<dd class=\"left_nav_item left_nav_item_current\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='我的短信.htm'\">站内短信管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信发送.htm\">新建站内短信</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"我的短信.htm\">收件箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信草稿箱.htm\">草稿箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信发件箱.htm\">发件箱</a></dd>");
        document.writeln("<dd style=\"display:none;\"><a href=\"站内短信垃圾箱.htm\">垃圾箱</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    if (Show == "个人信息管理") {
        document.writeln("<dt class=\"left_nav_opened\" onclick=\"window.location.href='密码修改.htm'\">个人信息管理</dt>");
        if (CurrentShow == "密码修改")
            document.writeln("<dd style=\"left_nav_item left_nav_item_current\"><a href=\"密码修改.htm\">密码修改</a></dd>");
        else
            document.writeln("<dd style=\"left_nav_item\"><a href=\"密码修改.htm\">密码修改</a></dd>");
    }
    else {
        document.writeln("<dt class=\"left_nav_closed\" onclick=\"window.location.href='密码修改.htm'\">个人信息管理</dt>");
        document.writeln("<dd style=\"display:none;\"><a href=\"密码修改.htm\">密码修改</a></dd>");
    }
    document.writeln("<dd class=\"nav_spilt\"></dd>");

    document.writeln("</dl>");
    ShowLeftItemsBottom();
}

function ShowLeftItemsTop() {
    document.writeln("<table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\">");
    document.writeln("<tr>");
    //    document.writeln("<td id=\"left_nav_back_top_left\"></td>");
    //    document.writeln("<td id=\"left_nav_back_top\"></td>");
    //    document.writeln("<td id=\"left_nav_back_top_right\"></td>");
    //    document.writeln("</tr>");
    //    document.writeln("<tr>");
    //    document.writeln("<td id=\"left_nav_left\"\"><div align=\"center\" id=\"left_nav_open\"></div></td>");
    //    document.writeln("<td id=\"left_nav\"\">");
    document.writeln("<td>");
}

function ShowLeftItemsBottom() {
    document.writeln("</td>");
    //    document.writeln("<td id=\"left_nav_right\"\"></td>");
    //    document.writeln("</tr>");
    //    document.writeln("<tr>");
    //    document.writeln("<td id=\"left_nav_back_bottom_left\"></td>");
    //    document.writeln("<td id=\"left_nav_back_bottom\"></td>");
    //    document.writeln("<td id=\"left_nav_back_bottom_right\"></td>");
    //    document.writeln("</tr>");
    document.writeln("</table>");
}

//根据Table高度重新计算Table外嵌套的Div的高度
//divName Table外嵌套的Div的客户端ID
//divName Table的客户端ID
function TableHeight(divName, tableName) {
    try {
        //重新设置NAV的高度并记录高度
        //alert(document.getElementById(tableName).offsetHeight);
        document.getElementById("nav").style.height = leftHeight;
        //leftHeight=document.getElementById("nav").clientHeight;

        var table = document.getElementById(tableName);
        var div = document.getElementById(divName);
        if (table != null && div != null) {
            //alert(document.getElementById("body-wrap").offsetHeight);
            var MaxHeight = 350;
            if (table.offsetHeight + 50 > MaxHeight)
                div.style.height = MaxHeight;
            else
                div.style.height = table.offsetHeight + 50;
            bodyresize();
        }
        else {
        }
    }
    catch (e) { alert(e); }
    //    alert(document.getElementById("body-wrap").offsetHeight);
}
